<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<title>Insert title here</title>
<link
	href="https://cdn.bootcss.com/bootstrap/3.3.7/css/bootstrap.min.css"
	rel="stylesheet">
</head>
<body>
	<jsp:include page="../top.jsp"></jsp:include>
	<div class="container">
		<div class="row clearfix">
			<a href="../supplier/toaddsupplier">增加供应商</a>
			<div class="col-md-12 column">
				<table class="table">
					<thead>
						<tr>
							<th style="vertical-align: middle !important;text-align: center;">供应商编号</th>
							<th style="vertical-align: middle !important;text-align: center;">供应商名称</th>
							<th style="vertical-align: middle !important;text-align: center;">供应商地址</th>
							<th style="vertical-align: middle !important;text-align: center;">供应商联系方式</th>
							<th style="vertical-align: middle !important;text-align: center;">供应商联系人</th>
							<th style="vertical-align: middle !important;text-align: center;">操作</th>
						</tr>
					</thead>
					<tbody>
						<c:forEach items="${supplier }" var="item">
							<tr>
								<td style="vertical-align: middle !important;text-align: center;">${item.supplier_id}</td>
								<td style="vertical-align: middle !important;text-align: center;">${item.supplier_name }</td>
								<td style="vertical-align: middle !important;text-align: center;">${item.supplier_address }</td>
								<td style="vertical-align: middle !important;text-align: center;">${item.supplier_telephone }</td>
								<td style="vertical-align: middle !important;text-align: center;">${item.supplier_contact }</td>
								<td style="vertical-align: middle !important;text-align: center;">
									<!--修改按钮-->
									<button class="btn btn-default btn-xs btn-info"
										onclick="location.href='../supplier/updateSupplierInfo?supplier_id=${item.supplier_id}'">修改</button>
									<!--删除按钮-->
									<button class="btn btn-default btn-xs btn-danger btn-primary"
									 onclick="location.href='../supplier/deleteSupplierInfo?supplier_id=${item.supplier_id}'">删除</button>
								</td>
							</tr>
						</c:forEach>
					</tbody>
				</table>
			</div>
		</div>
	</div>
	<!-- jQuery (necessary for Bootstrap's JavaScript plugins) -->
	<script src="https://cdn.bootcss.com/jquery/1.12.4/jquery.min.js"></script>
	<!-- Include all compiled plugins (below), or include individual files as needed -->
	<script
		src="https://cdn.bootcss.com/bootstrap/3.3.7/js/bootstrap.min.js"></script>
</body>
</html>